from selenium.webdriver.common.by import By

from common.base import Base


class GoodsCartPage(Base):
    def goods_name_cart(self):  # 购物车商品名称
        return self.find_element_text((By.XPATH, '//form[@id="formCart"]'))
        # return self.find_element_text((By.XPATH, '//a[@target="_blank" and @class="f6"]'))

    def del_cart(self):
        self.click((By.XPATH, '//input[@value="清空购物车"]'))
